<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>方案评价</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1.0">
    {CSS href="__ADDONSTATIC__css/font.css" /}
    {CSS href="__ADDONSTATIC__css/xadmin.css" /}
    {js href='__ADDONSTATIC__js/jquery-3.2.1.min.js' /}
    {CSS href="__ADDONSTATIC__css/css.css" /}

    {js href='__ADDONSTATIC__js/xadmin.js' /}
    {js href='__ADDONSTATIC__js/util.js' /}
    <script src="https://cdn.jsdelivr.net/npm/vue"></script>
    {js href='__ADDONSTATIC__lib/layui/layui.js' /}
    <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
    <!--[if lt IE 9]>
    <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
    <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
</head>
<body style="background: #f0eeee;">
<div class="center">
    <div class="answer_bg" style="text-align: center">
        <br>
        <h1>方案评价</h1>
    </div>
    <!--甲方评价信息-->
    <div class="answer_bg">
        <div class="project_k">
            <div class="project_title">
                <strong>项目名称：</strong>
                <span>{$solveInfo.pname}({$solveInfo.stageName})</span>
            </div>
        </div>
        <div class="project_k">
            <div class="project_title">
                <strong>甲方评价：</strong>
                <span>{$solveInfo.status}</span>
            </div>
        </div>
        <div class="project_k">
            <div class="project_title">
                <strong>评价详情：</strong>
                    {volist name='evaluateInfo' id='l'}
                    <div class="font-noraml"><span>{$l.key}: </span><span>{$l.value}</span></div>
                    {/volist}
            </div>
        </div>
        <div class="project_k">
            <div class="project_title">
                <strong>评价备注：</strong>
                <span>{$solveInfo.remark}</span>
            </div>
        </div>
    </div>
    <!--负责人方案信息-->
    <div class="answer_bg">
        <div class="project_k">
            <div class="project_title">
                <strong>反馈负责人：</strong>
                <span>{$solveInfo.memberName}({$solveInfo.partName})</span>
            </div>
        </div>
        <div class="project_k">
            <div class="project_title">
                <strong>反馈详情：</strong>
                <span>{$solveInfo.solveContent}</span>
            </div>
        </div>
    </div>
    <!--甲方评价-->
    <div class="answer_bg">
        <div class="project_k">
            <div class="project_stit">
                <span>请您对我们的反馈作出评价</span>
            </div>
            <div class="project_sele">
                <select name="status">
                    {if condition="$solve.evaluateStatus == 1"}
                    <option value="1" selected>满意</option>
                    <option value="0">不满意</option>
                    {elseif condition="$solve.evaluateStatus == 0" /}
                    <option value="0" selected>不满意</option>
                    <option value="1">满意</option>
                    {else/}
                    <option value="1">满意</option>
                    <option value="0">不满意</option>
                    {/if}
                </select>
            </div>
        </div>
        <div class="project_k">
            <div class="project_stit">
                <span/>备注：</span>
            </div>
            <div class="project_sele">
                <textarea name="remark" placeholder="请输入内容" class="layui-textarea">{$solve.evaluateContent}</textarea>
            </div>
        </div>
        <div class="reg_btn2">
            <button onclick="sendMessage({$solveInfo.id})" class="layui-btn layui-btn-lg layui-btn-normal">提交评价</button>
        </div>
    </div>
</div>
</body>
<script>
    //选项卡
    layui.use('element', function () {
        var element = layui.element;
    });

    /**
     * 保存评价信息
     * @param projectId
     * @param statusId
     */
    function sendMessage(sId) {
        var data = {};
        data.remark = $("textarea").val();
        data.status = $("select[name='status']").val();
        data.id=sId;
        ajaxUrl("{:addonUrl('Wap/evaSolve')}",
            data, function (data) {
                layer.alert(data.message, {}, function (index) {
                    layer.close(index);
                    // 微信页面关闭
                    WeixinJSBridge.invoke('closeWindow', {}, function (res) {});
                });
            });
    }
</script>
</html>